package day02;

import java.io.IOException;

import javax.servlet.ServletException;
import javax.servlet.ServletRequest;
import javax.servlet.ServletResponse;
import javax.servlet.http.HttpServlet;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;

public class DemoServlet extends HttpServlet{
	public DemoServlet() {
		System.out.println("构造器");
	}
	
	@Override
	public void init() throws ServletException {
		System.out.println("servlet初始化");
	}
	
	@Override
	protected void service(HttpServletRequest arg0, HttpServletResponse arg1) throws ServletException, IOException {
		super.service(arg0, arg1);
		
		System.out.println("service方法");
	}
	
	@Override
	protected void doGet(HttpServletRequest req, HttpServletResponse resp) throws ServletException, IOException {
		System.out.println(Thread.currentThread());
		System.out.println("doget方法");
	}
	@Override
	public void destroy() {
		System.out.println("销毁方法");
	}
}
